package org.zxp.designpattern.agent.st;

import org.zxp.designpattern.agent.UserDaoImpl;
import org.zxp.designpattern.agent.UserDaoIntf;

/**
 * @program: effectiveJava
 * @description:
 * @author: X-Pacific zhang
 * @create: 2019-08-27 15:57
 **/
public class UserDaoProxy implements UserDaoIntf {
    UserDaoIntf userDao = new UserDaoImpl();
    @Override
    public int insert(String user) {
        System.out.println("静态代理插入前");
        userDao.insert(user);
        System.out.println("静态代理插入后");
        return 0;
    }
}
